<template>
  <el-row :gutter="10" class="mb8">
    <el-col :span="1.5">
      <el-button
        type="primary"
        icon="el-icon-plus"
        size="mini"
        @click="handleAddData"
        v-hasPermi="['system:sort:add']"
        :disabled="addAvail"
      >新增</el-button>
    </el-col>
    <el-col :span="1.5">
      <el-button
        type="danger"
        icon="el-icon-delete"
        size="mini"
        :disabled="multiple"
        @click="handleDeleteData"
        v-hasPermi="['system:sort:remove']"
      >删除</el-button>
    </el-col>
    <el-col :span="1.5">
      <el-button
        type="warning"
        icon="el-icon-download"
        size="mini"
        @click="handleExportData"
        v-hasPermi="['system:sort:export']"
      >导出</el-button>
    </el-col>
    <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
  </el-row>
</template>

<script>
export default {
  name: 'rightBtns',
  props:['handleAdd','handleUpdate','handleDelete','handleExport','showSearch','getList','single','multiple', 'IdRulesForm', 'addAvail'],
  methods:{
    handleAddData(){
      this.handleAdd()
    },
    handleUpdateData(){
      this.handleUpdate()
    },
    handleDeleteData(){
      this.handleDelete()
    },
    handleExportData(){
      this.handleExport()
    }
  }
}
</script>

<style scoped>

</style>
